<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>备选人列表</title>
<link rel="stylesheet" href="__PUBLIC__/Css/public.css" />
<link rel="stylesheet" href="__PUBLIC__/Css/css.css" />
<script type="text/javascript" src="__PUBLIC__/Js/jquery.js"></script>
<script type="text/javascript" src="__PUBLIC__/Js/jBox/jquery.jBox-2.3.min.js"></script>
<script type="text/javascript" src="__PUBLIC__/Js/jBox/jquery.jBox-zh-CN.js"></script>
<link type="text/css" rel="stylesheet" href="__PUBLIC__/Js/jBox/Skins2/Blue/jbox.css"/>
<script type="text/javascript">
var type='{$Think.session.type}';
var len=0;
if(type=='1'){
	len=5;
}else if(type=='2'){
	len=4;
}
$(function(){
	$("#sendurl").click(function(){
		if($("#pageNo").val()==''){
			$.jBox.tip("请输入跳转到的页数");
		}else{
			window.location.href="__SELF__/p/"+$("#pageNo").val();
		}
	});
	$(".grjjid").click(function(){
		var nowlen=$(".grjjid:checked").length;
		$("#result").html("已经选择"+nowlen+"个结果");
		if(nowlen>len){
			$.jBox.tip("最多选择"+len+"个结果");
			$(this).removeAttr("checked");
		}
	});
});
function showDitail(id){
	top.$.jBox("iframe:__GROUP__/main/showinfo/jtype/2/id/"+id, {
		title: "详细资料",
		width: 700,
		height: 500,
		buttons: { '关闭': true }
	});
}
function checkform(){
	var nowlen=$(".grjjid:checked").length;
	if(nowlen==0){
		$.jBox.error("请勾选需要上报的结果","错误");
		return false;
	}
	if(nowlen<len){
		$.jBox("请勾选<span style='color:red'>"+len+"</span>个结果后再次提交，已经选择"+nowlen+"个","错误");
		return false;
	}
	return true;
}
</script>
</head>

<body bgcolor="#C8C8C6">
<div class="userlist">
	<div class="list_top">
		<div class="left" style="font-size:18px;">组织奖</div>
		<eq name="Think.session.level" value="2">
		<div class="left" style="margin-left:20px;">按省份查询
			<select name="province" id="province">
				<option value="全部">全部</option>
				<volist name="proList" id="pro">
					<option value="{$pro.PROVINCE}" 
						<eq name="pro.PROVINCE" value="$province">selected="selected"</eq>
					>{$pro.PROVINCE}</option>
				</volist>
			</select>
		</div>
		</eq>
		<div class="left" style="margin-left:20px;" id="result"></div>
		<div class="right listpage">{$jPage} 
		<input type="text" name="p" id="pageNo" class="text_i" style="width:50px;" />
		<a href="javascript:void(0)" class="button_l"><span class="button_r" id="sendurl">跳转</span></a></div>
		<div style="clear:both;"></div>
	</div>
	<div class="list_bottom">
		<form action="__URL__/insert" method="post" class="list_form" onsubmit="return checkform();">
			<table width="100%" cellpadding="0" cellspacing="0" background="0" class="list_table">
				<tr>
					<th width="50">选择</th>
					<th width="100">申报类别</th>
					<th width="100">组织名称</th>
					<th width="150">成立时间</th>
					<th width="100">负责人</th>
					<th width="100">职务</th>
					<th width="100">联系电话</th>
					<th width="200">创建时间</th>
					<th>操作</th>
				</tr>
				<volist name="jList" id="vo">
				<tr>
					<td height="25" align="left"><input type="checkbox" name="jid[]" class="grjjid" value="{$vo.id}" /></td>
					<td align="center">{$vo.SBLB}</td>
					<td align="left">{$vo.ZZMC}</td>
					<td align="left">{$vo.CLSJ}</td>
					<td align="left">{$vo.FZR}</td> 
					<td align="left">{$vo.ZW}</td>
					<td align="left">{$vo.LXDH}</td>
					<td align="left">{$vo.ctime}</td>
					<td>
					<a href="__GROUP__/main/sort/jtype/1/id/{$vo.id}" class="button_l"><span class="button_r">前置</span></a>
					<a href="javascript:void(0)" class="button_l"><span class="button_r" onclick="showDitail({$vo.id})">查看详情</span></a>
					</td>
				</tr>
				</volist>
				<tr>
					<td colspan="10">
						<eq name="level" value="1"><input type="submit" value="提交勾选结果" /><input type="hidden" name="jtype" value="{$jtype}" /></eq>
					</td>
				</tr>
			</table>
		</form>
	</div>
</div>
</body>
</html>
